//
// Created by jwhww on 25-11-2.
//

#ifndef ROULETTE_H
#define ROULETTE_H

#endif //ROULETTE_H
//M3508供弹轮盘堵转
#define BLOCKING_AMPLITUDE                      (3000) //堵转时电流振幅
#define BLOCKING_GATE_SPEED                     (20) //堵转时速度门限
#define BLOCKING_GATE_CURRENT                   (4000) //堵转时电流门限
#define BLOCKING_TIM                            (100) //堵转检测时间，单位：ms
#define ROULETTE_SCALE                          (157310.f)  //轮盘角度范围，157310 = 8292 * DECELERATION_RATIO_M3508
#define ROULETTE_BACK_DISTANCE                  (5000)  //堵转后回转轮盘编码器距离，范围 0~ROULETTE_SCALE
#define CALCULATE_ROULETTE_DIFF(x)              ((float)(x) / 60.f / 1000.f / 19.203f * ROULETTE_SCALE * PERIOD_TIM_6_MS)

void JJ_motor_roulette_blocking_meter(MotorInfo *motor_info, const MotorID motor_id);
